import request from '@/utils/request'

export function subcontractorList(data) {
  return request({
    url: '/subcontractor',
    method: 'get',
    params: data
  })
}

export function updataSubcontractor(data) {
  return request({
    url: '/subcontractor',
    method: 'put',
    data
  })
}
export function detailSubcontractor(id) {
  return request({
    url: '/subcontractor/' + id,
    method: 'get'
  })
}
export function deleteSubcontractor(id) {
  return request({
    url: '/subcontractor/' + id,
    method: 'delete'
  })
}
export function createSubcontractor(data) {
  return request({
    url: '/subcontractor/add',
    method: 'post',
    data
  })
}
// 分包商类型
export function getSubcontractorType() {
  return request({
    url: '/subcontractor/getSubcontractorType',
    method: 'get'
  })
}
